package com.sfj.system.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.sfj.system.dto.LoginResDTO;
import com.sfj.system.dto.userinfo.UserInfoQueryDTO;
import com.sfj.system.dto.userinfo.UserTaskDTO;
import com.sfj.system.entity.UserInfoEntity;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;


public interface UserInfoMapper {

    UserInfoEntity selectByPrimaryKey(@Param("userId") Integer userId);

    LoginResDTO selectByUserName(@Param("userName") String userName);

    UserInfoEntity selectByPoliceNum(@Param("policeNum") String policeNum);

    //List<ProcessRoleDTO> getByUserNameList(@Param("userName") String userName, @Param("userId") String userId);


    int insertSelective(@Param("record") UserInfoEntity record);

    int updateSelective(@Param("record") UserInfoEntity record);

    int deleteByPrimaryKey(@Param("userId") Integer userId);

    int deleteBatch(@Param("userIds") List<String> userIds);

    //List<UserInfoEntity> searchListByName(@Param("userName") String userName);
    //
    //List<UserInfoEntity> getUserByIdList(@Param("userIds") List<String> ids);
    //
    IPage<UserInfoEntity> queryUserInfoList(IPage<?> iPage, @Param("record") UserInfoQueryDTO record);

    void insertBatch(@Param("entityList") List<UserInfoEntity> userList);

    List<UserTaskDTO> queryUserByTask(@Param("entityIdList")List<Integer>  levelList);

    List<Map<Integer, String>> getUserNameByIds(@Param("entityList") List<Integer> userIds);
}

